import { AsrData } from "./AsrData";
import { SctData } from "./SctData";
import { PrfData } from "./PrfData";
import { EseData } from "./EseData";
import { AirlineIcaoData } from "./AirlineIcaoData";
import { AirportIcaoData } from "./AirportIcaoData";
import { AircraftIcaoData } from "./AircraftIcaoData";
import { SymbolDrawer } from "./SymbolDrawer";
import { SymbolConfig } from "./SymbolConfig";
import { createEmptyVatsimData, IVatsimData } from "../vatsimApi/interfaces/IVatsimData";

export class RadarRenderData {
    asr: Map<string, AsrData> = new Map();
    ese: EseData = new EseData();
    prf: Map<string, PrfData> = new Map();
    sct: SctData = new SctData();
    airlineIcaoData: Map<string, AirlineIcaoData> = new Map;
    airportIcaoData: Map<string, AirportIcaoData> = new Map;
    aircraftIcaoData: Map<string, AircraftIcaoData> = new Map;
    /**
     * key为SymbolConfig.group-SymbolConfig.type
     */
    symbols: Map<string, SymbolConfig> = new Map;
    airportSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    ndbSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    vorSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    fixSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aStandbySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aPrimaryRadarOnlySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrACModeSecRadarOnlySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrSModeSecRadarOnlySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrPrimAndACModeSecSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrPrimAndSModeSecSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrACModeIndentingSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCorrSModeIndentingSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aFlightPlanTrackSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aCoastingSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    historyDotSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    groundAircraftSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrACModeSecRadarOnlySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrSModeSecRadarOnlySymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrPrimAndACModeSecSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrPrimAndSModeSecSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrACModeIndentingSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    aUnCorrSModeIndentingSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    groundVehicleSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    groundRotorcraftSymbolDrawer: SymbolDrawer = new SymbolDrawer();
    vatsimData: IVatsimData = createEmptyVatsimData();
}

export let RenderData: RadarRenderData = new RadarRenderData();

export function resetRenderData() {
    RenderData = new RadarRenderData();
}